<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <ui:composition template="/template.xhtml">
        <f:metadata>
             <f:event listener="#{sistemasController.getMuralHome}" type="preRenderComponent" id="fevent"/>
        </f:metadata> 
        <ui:define name="body">
            
            <p:fieldset legend="Mural" style="margin-bottom:20px">
                <h:outputText value="#{sistemasController.selected.mural}" />
            </p:fieldset>   

            <p:fieldset legend="Primeiro Acesso?" style="margin-bottom:20px">
                <img src="/embrapa/faces/i_guia.jpg" alt="" width="100%"/>
            </p:fieldset>
            
            <p:fieldset legend="Evento Dia" style="margin-bottom:20px">
                <p:dataTable id="datalist"
                             emptyMessage="Nenhum registro localizado"
                             value="#{sigifEventosintController.getEventoDia()}" 
                             var="item">
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_desObs}"/>
                            </f:facet>
                            <h:outputText value="#{item.desObs}"/>
                        </p:column>
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_datIniVig}"/>
                            </f:facet>
                            <h:outputText value="#{item.datIniVig}">
                                <f:convertDateTime pattern="dd/MM/yyyy" />
                            </h:outputText>
                        </p:column>
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_datFimVig}"/>
                            </f:facet>
                            <h:outputText value="#{item.datFimVig}">
                                <f:convertDateTime pattern="dd/MM/yyyy" />
                            </h:outputText>
                        </p:column>
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_horIni}"/>
                            </f:facet>
                            <h:outputText value="#{item.horIni}">
                                <f:convertDateTime pattern="HH:mm:ss" />
                            </h:outputText>
                        </p:column>
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_horFim}"/>
                            </f:facet>
                            <h:outputText value="#{item.horFim}">
                                <f:convertDateTime pattern="HH:mm:ss" />
                            </h:outputText>
                        </p:column>
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_desLocal}"/>
                            </f:facet>
                            <h:outputText value="#{item.desLocal}"/>
                        </p:column>
                        <p:column>
                            <f:facet name="header">
                                <h:outputText value="#{bundle.ListSigifEventosintTitle_desCidade}"/>
                            </f:facet>
                            <h:outputText value="#{item.desCidade}"/>
                        </p:column>
                    </p:dataTable>                   
            </p:fieldset> 
            
            <p:fieldset legend="Cliente Aniversariante Dia" style="margin-bottom:20px">
                <p:dataTable id="datalistcliente"
                             emptyMessage="Nenhum registro localizado"
                             value="#{tbInstController.getClienteAniversariante()}" 
                             var="item">
                    <p:column> 
                        <f:facet name="header">
                            <h:outputText value="#{bundle.ListTbInstTitle_nomFantasia}"/>
                        </f:facet>
                        <h:outputText value="#{item.nomFantasia}"/>
                    </p:column>
                    <p:column> 
                        <f:facet name="header">
                            <h:outputText value="#{bundle.ListTbInstTitle_desFone1}"/>
                        </f:facet>
                        <h:outputText value="#{item.desFone1}"/>
                    </p:column>
                    <p:column> 
                        <f:facet name="header">
                            <h:outputText value="#{bundle.ListTbInstTitle_desEmail}"/>
                        </f:facet>
                        <h:outputText value="#{item.desEmail}"/>
                    </p:column>
                </p:dataTable>                    
            </p:fieldset> 

            <p:fieldset legend="Cliente Novo" style="margin-bottom:20px">
                <p:dataTable id="datalistclientenovo"
                             emptyMessage="Nenhum registro localizado"
                             value="#{tbInstController.getClienteNovo()}"  
                             var="item">
                    <p:column> 
                        <f:facet name="header">
                            <h:outputText value="#{bundle.ListTbInstTitle_nomFantasia}"/>
                        </f:facet>
                        <h:outputText value="#{item.nomFantasia}"/>
                    </p:column>
                    <p:column> 
                        <f:facet name="header">
                            <h:outputText value="#{bundle.ListTbInstTitle_desFone1}"/>
                        </f:facet>
                        <h:outputText value="#{item.desFone1}"/>
                    </p:column>
                    <p:column> 
                        <f:facet name="header">
                            <h:outputText value="#{bundle.ListTbInstTitle_desEmail}"/>
                        </f:facet>
                        <h:outputText value="#{item.desEmail}"/>
                    </p:column>
                </p:dataTable>                    
            </p:fieldset>   
            
        </ui:define>
    </ui:composition>

</html>